#include "abstractnode.h"
#include "nodes/operators.h"
#include "nodes/constant.h"

AbstractNode::~AbstractNode()
{

}

AbstractNode * AbstractNode::negate(const YYLTYPE & pos)
{
  return new OperatorNode(pos,this,new Constant(YYLTYPE(),(long long)-1),"*");
}


bool AbstractNode::transformCode(ParentData *)
{
	return true;
}

bool AbstractNode::canBeTransformedFromAssignment(ParentData * data, bool * error)
{
	return false;
}

bool AbstractNode::isOperator()
{
	return false;
}

std::string AbstractNode::getType(ParentData * data)
{
	return UNKNOWN_TYPE;
}


bool AbstractNode::checkLogic(ParentData * data)
{
	return true;
}

bool AbstractNode::isLValue(ParentData * data)
{
	return false;
}

bool AbstractNode::isIdentifier()
{
	return false;
}

bool   AbstractNode::isResultReturn()
{
	return false;
}

void AbstractNode::checkCommonErrors(ParentData * data)
{
}

void AbstractNode::fillConstant(ParentData * data)
{
}

void AbstractNode::produceCode(ParentData * data)
{
}